<template>
    <div class="cms-pagination">
        <div class="cms-pagination-total">共 <em>{{pageData.total}}</em> 条记录</div>
        <el-pagination v-if="pageData.last_page > 1"
                background
                :page-size="pageData.per_page"
                layout="prev, pager, next, jumper"
                :total="pageData.total"
                :currentPage="pageData.currentPage"
                @current-change="changePage">
        </el-pagination>
    </div>
</template>

<script>
    export default {
        props:['pageData','params'],
        methods: {
            //分页
            changePage(val) {
                this.params.page = val;
                this.$emit('list');
            },
        }
    }
</script>

